#include "Map.h"

Map::Map(void){
	
	
}
Map::~Map(void){
	
	
}/**/


void Map::Nuskaitymas(){
	N = 0;
	food = 0;
	std::ifstream fd("Map.txt");
	for (int i  = 0; i < 10;i++)
		for (int j = 0; j < 10; j++){
			fd >> M[i][j];
			if (M[i][j] == 1) N++;
			if (M[i][j] == 2) food++;
		}

	fd.close();
}
bool Map::Tikrinti(int x, int y)
{
  if (M[x][y] == 1) return false;
  if (M[x][y] == 0) return true;

}

bool Map::Finish()
{
	
	for (int i  = 0; i < 10;i++)
		for (int j = 0; j < 10; j++)
			if (M[i][j] == 2) return false;

	return true;

}
